<!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>Document</title>
    <style>
    </style>
</head>

<body>
    <input type="file" name="file" id="file" multiple>
    <script type="module">
        const input = document.querySelector("#file");
        input.addEventListener('change', (e) => {
            Array.from(e.target.files).forEach(file => {
                console.log(file.name, file.lastModified, file.size, file.type);
                let fileReader = new FileReader();
                fileReader.onload = fileLoadHandle;
                fileReader.readAsDataURL(file);
            })
        })

        function fileLoadHandle(e) {
            console.log(e.target);
        }
        import axios from './node_modules/axios/dist/esm/axios.js'
        let a = await axios.get('https://api.vvhan.com/api/text/joke').then(e=>e.data)
        console.log(a);
        
    </script>
</body>

</html>